<?php

namespace Itwmw\Attributes\Validate;

class EventFunc
{
    protected array $args = [];

    /**
     * @param string|array<callable-string> $method  当前数据类的方法
     * @param mixed                         ...$args 传递给方法的参数
     */
    public function __construct(
        public readonly string|array $method,
        ...$args
    ) {
        $this->args = $args;
    }

    public function getArgs(): array
    {
        return $this->args;
    }
}
